package com.gitee.mqttclient.exception;

import com.gitee.mqttclient.client.TopicInfo;
import org.eclipse.paho.client.mqttv3.MqttException;

/**
 * @author thc
 */
public class TopicSubscribeException extends Exception {

    private static final long serialVersionUID = -6835498321482678413L;

    private final MqttException mqttException;
    private final TopicInfo topicInfo;

    public TopicSubscribeException(MqttException mqttException, TopicInfo topicInfo) {
        super(mqttException);
        this.mqttException = mqttException;
        this.topicInfo = topicInfo;
    }

    public MqttException getMqttException() {
        return mqttException;
    }

    public TopicInfo getTopicInfo() {
        return topicInfo;
    }
}
